﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Collections.ObjectModel;
using System.CodeDom.Compiler;

namespace RobotBattle2.Scripting {
	public sealed class Script : AstNode {
		public string Name { get; set; }
		public string Author { get; set; }
		public string Version { get; set; }

		public MethodDeclarationCollection Methods { get { return m_Methods; } }
		private MethodDeclarationCollection m_Methods = new MethodDeclarationCollection();

		public CompilerErrorCollection Errors { get { return m_Errors; } }
		private CompilerErrorCollection m_Errors = new CompilerErrorCollection();

		public override void Dump(IndentedTextWriter writer) {
			foreach (var item in Methods) {
				item.Dump(writer);
			}
		}
	}
}
